import javax.swing.JFrame;
import javax.swing.JButton;
import java.awt.Label;
import javax.swing.JTextField;
import javax.swing.SwingConstants;
import javax.swing.DropMode;
import javax.swing.JPasswordField;



public class ex4 extends JFrame{
	private JTextField textField;
	private JPasswordField passwordField;
	public ex4() {
		setTitle("\u767B\u5F55");
		JFrame frame =new JFrame();
		frame.setSize(450, 300);
		frame.setLocation(400,200);
		//frame.add(getContentPane());
		
		getContentPane().setLayout(null);
		
		Label label = new Label("\u56FE\u7247\u533A");
		label.setAlignment(Label.CENTER);
		label.setBounds(10, 10, 414, 116);
		getContentPane().add(label);
		
		textField = new JTextField();
		textField.setEditable(false);
		textField.setHorizontalAlignment(SwingConstants.CENTER);
		textField.setBounds(284, 142, 117, 30);
		getContentPane().add(textField);
		textField.setColumns(10);
		
		JButton button = new JButton("\u767B\u5F55");
		button.setBounds(284, 222, 117, 30);
		getContentPane().add(button);
		
		passwordField = new JPasswordField();
		passwordField.setHorizontalAlignment(SwingConstants.CENTER);
		passwordField.setBounds(284, 182, 117, 30);
		getContentPane().add(passwordField);
		
		Label label_2 = new Label("\u5BC6\u7801\uFF1A");
		label_2.setAlignment(Label.CENTER);
		label_2.setBounds(192, 182, 69, 30);
		getContentPane().add(label_2);
		
		Label label_1 = new Label("\u7528\u6237\u540D\uFF1A");
		label_1.setAlignment(Label.CENTER);
		label_1.setBounds(192, 142, 69, 30);
		getContentPane().add(label_1);
		
		setVisible(true);
	}

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		new ex4();

	}
}
